3.119 \(\int \frac {c+d x^2+e x^4+f x^6}{x^4 (a+b x^2)} \, dx\)

Optimal. Leaf size=82 \[ \frac {b c-a d}{a^2 x}+\frac {\tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) \left (a^3 (-f)+a^2 b e-a b^2 d+b^3 c\right )}{a^{5/2} b^{3/2}}-\frac {c}{3 a x^3}+\frac {f x}{b} \]

[Out]

-1/3*c/a/x^3+(-a*d+b*c)/a^2/x+f*x/b+(-a^3*f+a^2*b*e-a*b^2*d+b^3*c)*arctan(x*b^(1/2)/a^(1/2))/a^(5/2)/b^(3/2)

________________________________________________________________________________________

Rubi [A]  time = 0.09, antiderivative size = 82, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 30, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.067, Rules used = {1802, 205} \[ \frac {\tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) \left (a^2 b e+a^3 (-f)-a b^2 d+b^3 c\right )}{a^{5/2} b^{3/2}}+\frac {b c-a d}{a^2 x}-\frac {c}{3 a x^3}+\frac {f x}{b} \]

Antiderivative was successfully verified.

[In]

Int[(c + d*x^2 + e*x^4 + f*x^6)/(x^4*(a + b*x^2)),x]

[Out]

-c/(3*a*x^3) + (b*c - a*d)/(a^2*x) + (f*x)/b + ((b^3*c - a*b^2*d + a^2*b*e - a^3*f)*ArcTan[(Sqrt[b]*x)/Sqrt[a]
])/(a^(5/2)*b^(3/2))

Rule 205

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]*ArcTan[x/Rt[a/b, 2]])/a, x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]

Rule 1802

Int[(Pq_)*((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*Pq*(a + b*x
^2)^p, x], x] /; FreeQ[{a, b, c, m}, x] && PolyQ[Pq, x] && IGtQ[p, -2]

Rubi steps

\begin {align*} \int \frac {c+d x^2+e x^4+f x^6}{x^4 \left (a+b x^2\right )} \, dx &=\int \left (\frac {f}{b}+\frac {c}{a x^4}+\frac {-b c+a d}{a^2 x^2}+\frac {b^3 c-a b^2 d+a^2 b e-a^3 f}{a^2 b \left (a+b x^2\right )}\right ) \, dx\\ &=-\frac {c}{3 a x^3}+\frac {b c-a d}{a^2 x}+\frac {f x}{b}+\frac {\left (b^3 c-a b^2 d+a^2 b e-a^3 f\right ) \int \frac {1}{a+b x^2} \, dx}{a^2 b}\\ &=-\frac {c}{3 a x^3}+\frac {b c-a d}{a^2 x}+\frac {f x}{b}+\frac {\left (b^3 c-a b^2 d+a^2 b e-a^3 f\right ) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{a^{5/2} b^{3/2}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.09, size = 83, normalized size = 1.01 \[ \frac {b c-a d}{a^2 x}-\frac {\tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) \left (a^3 f-a^2 b e+a b^2 d-b^3 c\right )}{a^{5/2} b^{3/2}}-\frac {c}{3 a x^3}+\frac {f x}{b} \]

Antiderivative was successfully verified.

[In]

Integrate[(c + d*x^2 + e*x^4 + f*x^6)/(x^4*(a + b*x^2)),x]

[Out]

-1/3*c/(a*x^3) + (b*c - a*d)/(a^2*x) + (f*x)/b - ((-(b^3*c) + a*b^2*d - a^2*b*e + a^3*f)*ArcTan[(Sqrt[b]*x)/Sq
rt[a]])/(a^(5/2)*b^(3/2))

________________________________________________________________________________________

fricas [A]  time = 0.68, size = 216, normalized size = 2.63 \[ \left [\frac {6 \, a^{3} b f x^{4} + 3 \, {\left (b^{3} c - a b^{2} d + a^{2} b e - a^{3} f\right )} \sqrt {-a b} x^{3} \log \left (\frac {b x^{2} + 2 \, \sqrt {-a b} x - a}{b x^{2} + a}\right ) - 2 \, a^{2} b^{2} c + 6 \, {\left (a b^{3} c - a^{2} b^{2} d\right )} x^{2}}{6 \, a^{3} b^{2} x^{3}}, \frac {3 \, a^{3} b f x^{4} + 3 \, {\left (b^{3} c - a b^{2} d + a^{2} b e - a^{3} f\right )} \sqrt {a b} x^{3} \arctan \left (\frac {\sqrt {a b} x}{a}\right ) - a^{2} b^{2} c + 3 \, {\left (a b^{3} c - a^{2} b^{2} d\right )} x^{2}}{3 \, a^{3} b^{2} x^{3}}\right ] \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x^6+e*x^4+d*x^2+c)/x^4/(b*x^2+a),x, algorithm="fricas")

[Out]

[1/6*(6*a^3*b*f*x^4 + 3*(b^3*c - a*b^2*d + a^2*b*e - a^3*f)*sqrt(-a*b)*x^3*log((b*x^2 + 2*sqrt(-a*b)*x - a)/(b
*x^2 + a)) - 2*a^2*b^2*c + 6*(a*b^3*c - a^2*b^2*d)*x^2)/(a^3*b^2*x^3), 1/3*(3*a^3*b*f*x^4 + 3*(b^3*c - a*b^2*d
 + a^2*b*e - a^3*f)*sqrt(a*b)*x^3*arctan(sqrt(a*b)*x/a) - a^2*b^2*c + 3*(a*b^3*c - a^2*b^2*d)*x^2)/(a^3*b^2*x^
3)]

________________________________________________________________________________________

giac [A]  time = 0.36, size = 81, normalized size = 0.99 \[ \frac {f x}{b} + \frac {{\left (b^{3} c - a b^{2} d - a^{3} f + a^{2} b e\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b} a^{2} b} + \frac {3 \, b c x^{2} - 3 \, a d x^{2} - a c}{3 \, a^{2} x^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x^6+e*x^4+d*x^2+c)/x^4/(b*x^2+a),x, algorithm="giac")

[Out]

f*x/b + (b^3*c - a*b^2*d - a^3*f + a^2*b*e)*arctan(b*x/sqrt(a*b))/(sqrt(a*b)*a^2*b) + 1/3*(3*b*c*x^2 - 3*a*d*x
^2 - a*c)/(a^2*x^3)

________________________________________________________________________________________

maple [A]  time = 0.01, size = 115, normalized size = 1.40 \[ -\frac {a f \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b}\, b}-\frac {b d \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b}\, a}+\frac {b^{2} c \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b}\, a^{2}}+\frac {e \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b}}+\frac {f x}{b}-\frac {d}{a x}+\frac {b c}{a^{2} x}-\frac {c}{3 a \,x^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((f*x^6+e*x^4+d*x^2+c)/x^4/(b*x^2+a),x)

[Out]

f*x/b-1/b*a/(a*b)^(1/2)*arctan(1/(a*b)^(1/2)*b*x)*f+1/(a*b)^(1/2)*arctan(1/(a*b)^(1/2)*b*x)*e-b/a/(a*b)^(1/2)*
arctan(1/(a*b)^(1/2)*b*x)*d+b^2/a^2/(a*b)^(1/2)*arctan(1/(a*b)^(1/2)*b*x)*c-1/3*c/a/x^3-1/a/x*d+1/a^2/x*b*c

________________________________________________________________________________________

maxima [A]  time = 2.94, size = 79, normalized size = 0.96 \[ \frac {f x}{b} + \frac {{\left (b^{3} c - a b^{2} d + a^{2} b e - a^{3} f\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b} a^{2} b} + \frac {3 \, {\left (b c - a d\right )} x^{2} - a c}{3 \, a^{2} x^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x^6+e*x^4+d*x^2+c)/x^4/(b*x^2+a),x, algorithm="maxima")

[Out]

f*x/b + (b^3*c - a*b^2*d + a^2*b*e - a^3*f)*arctan(b*x/sqrt(a*b))/(sqrt(a*b)*a^2*b) + 1/3*(3*(b*c - a*d)*x^2 -
 a*c)/(a^2*x^3)

________________________________________________________________________________________

mupad [B]  time = 0.11, size = 80, normalized size = 0.98 \[ \frac {f\,x}{b}-\frac {\frac {b\,c}{3\,a}+\frac {b\,x^2\,\left (a\,d-b\,c\right )}{a^2}}{b\,x^3}+\frac {\mathrm {atan}\left (\frac {\sqrt {b}\,x}{\sqrt {a}}\right )\,\left (-f\,a^3+e\,a^2\,b-d\,a\,b^2+c\,b^3\right )}{a^{5/2}\,b^{3/2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((c + d*x^2 + e*x^4 + f*x^6)/(x^4*(a + b*x^2)),x)

[Out]

(f*x)/b - ((b*c)/(3*a) + (b*x^2*(a*d - b*c))/a^2)/(b*x^3) + (atan((b^(1/2)*x)/a^(1/2))*(b^3*c - a^3*f - a*b^2*
d + a^2*b*e))/(a^(5/2)*b^(3/2))

________________________________________________________________________________________

sympy [B]  time = 2.27, size = 151, normalized size = 1.84 \[ \frac {\sqrt {- \frac {1}{a^{5} b^{3}}} \left (a^{3} f - a^{2} b e + a b^{2} d - b^{3} c\right ) \log {\left (- a^{3} b \sqrt {- \frac {1}{a^{5} b^{3}}} + x \right )}}{2} - \frac {\sqrt {- \frac {1}{a^{5} b^{3}}} \left (a^{3} f - a^{2} b e + a b^{2} d - b^{3} c\right ) \log {\left (a^{3} b \sqrt {- \frac {1}{a^{5} b^{3}}} + x \right )}}{2} + \frac {f x}{b} + \frac {- a c + x^{2} \left (- 3 a d + 3 b c\right )}{3 a^{2} x^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x**6+e*x**4+d*x**2+c)/x**4/(b*x**2+a),x)

[Out]

sqrt(-1/(a**5*b**3))*(a**3*f - a**2*b*e + a*b**2*d - b**3*c)*log(-a**3*b*sqrt(-1/(a**5*b**3)) + x)/2 - sqrt(-1
/(a**5*b**3))*(a**3*f - a**2*b*e + a*b**2*d - b**3*c)*log(a**3*b*sqrt(-1/(a**5*b**3)) + x)/2 + f*x/b + (-a*c +
 x**2*(-3*a*d + 3*b*c))/(3*a**2*x**3)

________________________________________________________________________________________